package com.xnyzc.lhy.didi.common.constants;

import com.xnyzc.lhy.common.penum.cms.EVehicleType;

public enum CXieChengVehicleType {

    vehTypeEconomic(1L, "经济型"),
    vehTypeComfortable(2L, "舒适型"),
    vehTypeLuxury(3L, "豪华型"),//携程没有开
    vehTypeBusiness(5L, "商务型"),
    //以下暂时无用
    smallBus10(14L, "10座小巴"),
    midBus19(15L, "19座中巴"),
    bigBus35(16L, "35座大巴"),
    bigbus43(17L, "43座大巴"),
    smallBus8(20L, "8座小巴"),
    midbus14(21L, "14座中巴"),
    bigbus30(22L, "30座大巴"),
    midBus25(23L, "25座中巴"),
    bigBus40(24L, "40座大巴"),
    bigBus53(26L, "53座大巴");

    Long code;
    String desc;

    CXieChengVehicleType(Long code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public Long getCode() {
        return code;
    }

    public String getDesc() {
        return desc;
    }

    public static EVehicleType getByType(int type) {
        switch (type) {
            case 1: {
                return EVehicleType.vehTypeEconomic;
            }
            case 2: {
                return EVehicleType.vehTypeComfortable;
            }
            case 3: {
                return EVehicleType.vehTypeLuxury;
            }
            case 5: {
                return EVehicleType.vehTypeBusiness;
            }
        }
        return null;
    }
    public static CXieChengVehicleType getByCType(int type) {
        switch (type) {
            case 0: {
                return CXieChengVehicleType.vehTypeEconomic;
            }
            case 1: {
                return CXieChengVehicleType.vehTypeComfortable;
            }
            case 2: {
                return CXieChengVehicleType.vehTypeLuxury;
            }
            case 3: {
                return CXieChengVehicleType.vehTypeBusiness;
            }
        }
        return null;
    }
}
